package com.tedu.egweibo.pojo.dto;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@Data
public class UserLoginDTO {

    //@Pattern()
    @NotBlank(message = "用户名1不能为空")
    @Size(min = 1,max = 30,message = "用户名长度在1-30之间")
    @ApiModelProperty(value = "用户名", required = true,example = "noname")
    private String username;
    @NotBlank(message = "密码不能为空")
    @Size(min = 6,max = 30,message = "密码长度在6-30之间")
    @ApiModelProperty(value = "密码", required = true,example = "123456")
    private String password;
}
